/*******************************************************************************
* Project: QSAR(Cute Software Architecture) 
*
* Copyright: Copyright(C) 2024 by YuetingBen, All Rights Reserved
*
* File name: NvmType.h
*
* Brief: ;
*
* Author: Yueting.Ben
*
* Module: Nvm
*
*******************************************************************************/

#ifndef NVMTYPE_H
#define NVMTYPE_H

/** HEADER FILES **/
#include "PlatformCfg.h" 


/** MACRO DEFINITION **/


/** TYPEDEF DEFINITION **/
typedef uint16 NvM_BlockIdType;
#define NvmConf_Block_DtcDataBlock0 ((NvM_BlockIdType)0u)
#define NvmConf_Block_DtcDataBlock1 ((NvM_BlockIdType)1u)
#define NvmConf_Block_DtcDataBlock2 ((NvM_BlockIdType)2u)
#define NvmConf_Block_DtcDataBlock3 ((NvM_BlockIdType)3u)
#define NvmConf_Block_DtcDataBlock4 ((NvM_BlockIdType)4u)
#define NvmConf_Block_DtcDataBlock5 ((NvM_BlockIdType)5u)
#define NvmConf_Block_DtcDataBlock6 ((NvM_BlockIdType)6u)
#define NvmConf_Block_DtcDataBlock7 ((NvM_BlockIdType)7u)
#define NvmConf_Block_DtcDataBlock8 ((NvM_BlockIdType)8u)
#define NvmConf_Block_DtcDataBlock9 ((NvM_BlockIdType)9u)
#define NvmConf_Block_Test0 ((NvM_BlockIdType)10u)
#define NvmConf_Block_Test1 ((NvM_BlockIdType)11u)
#define NvmConf_Block_Max ((NvM_BlockIdType)12u)


typedef uint8 NvM_RequestResultType;
#define NVM_REQ_OK                ((NvM_RequestResultType)0u)  /* The last asynchronous request has been finished successfully. */
#define NVM_REQ_NOT_OK            ((NvM_RequestResultType)1u)  /* The last asynchronous request has been finished unsuccessfully. */
#define NVM_REQ_PENDING           ((NvM_RequestResultType)2u)  /* An asynchronous request is currently being processed. */
#define NVM_REQ_INTEGRITY_FAILED  ((NvM_RequestResultType)3u)  /* Result of the last NvM_ReadBlock or NvM_(Pre)ReadAll is an integrity failure. */
#define NVM_REQ_BLOCK_SKIPPED     ((NvM_RequestResultType)4u)  /* The referenced block was skipped during a multi block request. */
#define NVM_REQ_NV_INVALIDATED    ((NvM_RequestResultType)5u)  /* The NV block is invalidated. */
#define NVM_REQ_CANCELED           ((NvM_RequestResultType)6u)  /* A WriteAll was cancelled. */
#define NVM_REQ_REDUNDANCY_FAILED ((NvM_RequestResultType)7u) /* A redundant block lost its redundancy. */
#define NVM_REQ_RESTORED_FROM_ROM ((NvM_RequestResultType)8u) /* Default data from ROM are restored. */

typedef struct
{
    uint8 test;
}NvM_ConfigType;

#endif

